﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using University.Workshop.Presenters;

namespace University.Workshop.Tests
{
    public class PurchaseReportMock:IReportPurchase
    {
        #region IMember IReportPurchase
        public string FilterBy
        {
            get;
            set;
        }

        public string OfProduct
        {
            get;
            set;
        }

        public string OfProvider
        {
            get;
            set;
        }

        public bool EnabledDateTo
        {
            get;
            set;
        }

        public bool EnabledDateFrom
        {
            get;
            set;
        }

        public bool EnabledProviderGroup
        {
            get;
            set;
        }

        public bool EnabledProductGroup
        {
            get;
            set;
        }

        public bool EnabledProviderText
        {
            get;
            set;
        }

        public bool EnabledProductText
        {
            get;
            set;
        }

        public DateTime DateFrom
        {
            get;
            set;
        }

        public DateTime DateTo
        {
            get;
            set;
        }
        #endregion

        #region ReportsCases
        public void EnableAndDisableControlsAll()
        {
            FilterBy = "Todos";
        }
        public void EnableAndDisableControlsProducts()
        {
            FilterBy = "Productos";
        }
        public void EnableAndDisableControlsProviders()
        {
            FilterBy = "Proveedores";
        }
        public void EnableAndDisableControlsDates()
        {
            FilterBy = "Fechas";
        }

        public void GenerateReportOfAllPurchases()
        {
            FilterBy = "Todos";
        }

        public void GenerateReportOfAProductFromTo()
        {
            FilterBy = "Productos";
            OfProduct = "med008";
            DateFrom = DateTime.Parse("10-May-11 10:30:54 PM");
            DateTo = DateTime.Now;
        }

        public void GenerateReportOfAProviderFromTo()
        {
            FilterBy = "Proveedores";
            OfProvider = "6408254";
            DateFrom = DateTime.Parse("10-May-11 10:30:54 PM");
            DateTo = DateTime.Now;
        }

        public void GenerateReportOfDates()
        {
            FilterBy = "Fechas";
            DateFrom = DateTime.Parse("10-May-11 10:30:54 PM");
            DateTo = DateTime.Now;
        }

        public void GenerateReportOfAProductFromToFail()
        {
            FilterBy = "Productos";
            OfProduct = "sapito";
            DateFrom = DateTime.Parse("10-May-11 10:30:54 PM");
            DateTo = DateTime.Now;
        }

        public void GenerateReportOfAProviderFromToFail()
        {
            FilterBy = "Proveedores";
            OfProvider = "7019419880";
            DateFrom = DateTime.Parse("10-May-11 10:30:54 PM");
            DateTo = DateTime.Now;
        }

        public void GenerateReportOfDatesFail()
        {
            FilterBy = "Fechas";
            DateFrom = DateTime.Parse("10-Jan-11 10:30:54 PM");
            DateTo = DateTime.Parse("11-Jan-11 10:30:54 PM");
        }
        #endregion
    }
}
